DmaFromPC 算子

Operator Library: Hardware Platform

对于 imaFlex 2 Dual 100、imaFlex CXP-12 Quad 和 imaFlex CXP-12 Penta 平台:

此算子提供从用户应用程序传输回采集卡的用户数据源,以便进行高级处理。DmaFromPC 算子不会解释传输的数据。相反,该算子以原始格式提供数据,每个值 8 位,具有 Parallelism 程度,这对应于 imaFlex 平台所使用的 PCIe 通道数量。

由 PC memory 中的 DMA 接收的所有数据都将源源不断地输入到 applet 的输出链接 O 中。DmaFromPC 算子仅支持一种输出格式:8 位无符号灰度(原始),Parallelism 为 64(imaFlex 2 Dual 100)/ 32(imaFlex CXP-12 Quad 和 imaFlex CXP-12 Penta),最大图像高度为 1。最大图像宽度必须能被 Parallelism 整除(imaFlex 2 Dual 100 为 64,imaFlex CXP-12 Quad 和 imaFlex CXP-12 Penta 为 32)。对于 imaFlex 2 Dual 100 平台,最大图像宽度为 2^31-64 = 2 147 483 584 像素(字节)。对于 imaFlex CXP-12 Quad 和 imaFlex CXP-12 Penta 平台,最大图像宽度为 2^31-32 = 2 147 483 616 像素(字节)。

最大图像宽度可由用户配置。输出链接的设置以及最大图像宽度必须大于或等于原始帧大小。否则,算子会向 VisualApplets 中注入图像,从而违反链接 Property。根据应用程序算法,此图像可能会在处理过程中导致问题。

DmaFromPC 算子需要一个类型为 DmaFromHostPort 的 VisualApplets 资源。请在资源对话框中为算子设置资源索引。查看 'Allocation of Device Resources' 了解更多信息。

适用于以下硬件平台
imaFlex 2 Dual 100
imaFlex CXP-12 Penta
imaFlex CXP-12 Quad

资源

对于所有 imaFlex 平台,该算子使用类型为 DmaFromHostPort 的资源,其范围为 [0 : 0],即整个设计中只能使用一个 DmaFromPC 算子。

如果您从 Analysis 菜单打开 FPGA Device Resources 对话框,则可以查看 FPGA 设备资源。设备资源是只读的:

imaFlex 平台的 FPGA 设备资源

图 431. imaFlex 平台的 FPGA 设备资源


I/O Property

Property 值
Operator Type M
Output Links imaFlex 2 Dual 100 的 O,图像数据输出
imaFlex CXP-12 Quad 和 imaFlex CXP-12 Penta 的 O,图像数据输出

Supported Link Format

Link Parameter imaFlex 2 Dual 100 的输出链接 O imaFlex CXP-12 Quad 和 imaFlex CXP-12 Penta 的输出链接 O
Bit Width 8 8
Arithmetic {unsigned} {unsigned}
Parallelism 64 32
Kernel Columns 1 1
Kernel Rows 1 1
Img Protocol {VALT_IMAGE2D} {VALT_IMAGE2D}
Color Format GRAY GRAY
Color Flavor NONE NONE
Max. Img Width 2 147 483 584 2 147 483 616
Max. Img Height 1 1

参数

无

使用示例

以下示例展示了 DmaFromPC 算子的使用: